package com.tsl.mapper;

import com.tsl.domain.pojo.TbSKU;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Update;

/**
 * <p>
 * 商品信息表 Mapper 接口
 * </p>
 *
 * @author 唐书亮
 * @since 2024-04-17
 */
@Mapper
public interface TbProductMapper extends BaseMapper<TbSKU> {
    //删除商品的时候判断它是否处于弃用状态
    @Update("update  digital_wanling.tb_product set isdelete = 0 where pid = #{id} and step = 0")
    Boolean deleteById(Integer id);

}
